package com.hibase.core.bireport.service.bi.impl;

import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.github.pagehelper.PageInfo;
import com.hibase.core.bireport.entity.bi.WmsBiConfig;
import com.hibase.core.bireport.entity.bi.vo.WmsBiConfigSearchVO;
import com.hibase.core.bireport.mapper.bi.WmsBiConfigMapper;
import com.hibase.core.bireport.service.bi.BiConfigService;
import com.hibase.core.mybatis.service.BaseServiceImpl;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author chenfeng
 * @since 2021-11-08
 */
@Service
public class BiConfigServiceImpl extends BaseServiceImpl<WmsBiConfigMapper, WmsBiConfig> implements BiConfigService {

    /**
     * 查询列表
     */
    @Override
    public PageInfo<WmsBiConfig> selectWmsBiConfigList(WmsBiConfigSearchVO searchVO) {

        return super.page(searchVO, new QueryWrapper<WmsBiConfig>());
    }

    /**
     * 改变记录
     */
    @Override
    @Transactional(rollbackFor = Exception.class)
    public void saveWmsBiConfig(WmsBiConfig entity) {

        super.store(entity);
    }

    /**
     * 查询详情
     */
    @Override
    public WmsBiConfig viewWmsBiConfig(String id) {

        WmsBiConfig entity = super.getById(id, true);

        return entity;
    }

    /**
     * 删除记录
     */
    @Override
    @Transactional(rollbackFor = Exception.class)
    public void deleteWmsBiConfig(String id) {

        super.deleteBy(id);
    }


    /**
     * 导出记录
     */
    @Override
    @Transactional(readOnly = true, rollbackFor = Exception.class)
    public void exportWmsBiConfig(WmsBiConfigSearchVO searchVO, HttpServletResponse response) {

    }
}
